package com.sailing.xjpb.common.map;

import lombok.Data;

/**
 * 地图坐标对象定义
 *
 * @author YaoWei
 * createDate: 2022-2-23
 */
@Data
public class MapPoint {
    /**
     * 经度
     */
    private double longitude;
    /**
     * 维度
     */
    private double latitude;

    public MapPoint(double longitude, double latitude) {
        this.longitude = longitude;
        this.latitude = latitude;
    }

    public MapPoint(String longitude, String latitude) {
        this.latitude = Double.parseDouble(latitude);
        this.longitude = Double.parseDouble(longitude);
    }

    @Override
    public String toString() {
        return longitude + "," + latitude;
    }

}
